package com.hlkj.baojin.service;

import com.hlkj.baojin.dao.IDeviceDao;
import com.hlkj.baojin.entity.DeviceErrLog;
import com.hlkj.baojin.entity.dto.Details;
import com.hlkj.baojin.entity.dto.DeviceDto;
import com.hlkj.baojin.entity.dto.CompanySearchDto;
import com.hlkj.baojin.entity.dto.DeviceSearchDto;
import com.hlkj.baojin.utils.bean.JsonResult;

import java.util.List;

/**
 * @author HULIN
 * @created with: baojin
 * @package com.hlkj.baojin.service
 * @description:
 * @date 2018/12/17 12:53
 * @modified By:
 * @Copyright © 2018 HAILIANG Info. Tech Ltd. All rights reserved.
 */
public interface DeviceService {

    void saveDevice(DeviceDto deviceDto);

    IDeviceDao getDeviceDao();

    void updateDevice(DeviceDto deviceDto);

    void deleteDevice(String deviceId);

    JsonResult findDevice(DeviceSearchDto deviceSearchDto);

    DeviceDto findDeviceById(String deviceId);

    List<String> getIdsByNameAndItem(String search);

    DeviceDto findDeviceByIdAndMonitorType(String deviceId, Integer monitorType);

    List<Details> getError(String deviceId);

    /**
     * 更新设备状态值 状态 0:使用中, 1:故障
     * @param deviceId
     * @param status
     */
    void updateDeviceStatus(String deviceId, Integer status);
}
